<template>
    <div>
        <el-tabs v-model="activeName" @tab-click="handleClick">
            <el-tab-pane label="收入日账-总视图" name="first">
                <tab1 ref="tab1"></tab1>
            </el-tab-pane>
            <el-tab-pane label="收入日账-出账专题" name="second">
                <tab2 ref="tab2"></tab2>
            </el-tab-pane>
        </el-tabs>
    </div>
</template>

<script>
import { $budgetAPI } from "@/api";
import { getSessionStorage } from "@/common/js/storage";
import { getCookie } from "@/common/js/cookie";
import { createSpanCharge, mergeSpan } from "@/utils/mixin";
import prefixAPI from "@/api/prefixAPI";
import tab1 from "./Bill-tab1New";
import tab2 from "./Bill-tab2";

export default {
    name: "incomeDayBillNew",
    components: {
        tab1,
        tab2
    },
    data() {
        return {
            activeName: "first"
        };
    },
    mounted() {
        var that = this;

        that.$refs.tab1.init();
    },
    methods: {
        handleClick(tab, event) {
            var that = this;
             
            if (tab.name == "first") {
                 that.$refs.tab1.init();
            }
            if (tab.name == "second") {
                 that.$refs.tab2.init();
            }
        }
    }
};
</script>

<style lang="scss"></style>
